package com.ekuaitu.kuaitu.adapter;

import android.content.Context;

import com.amap.api.services.help.Tip;
import com.ekuaitu.kuaitu.R;
import com.ekuaitu.kuaitu.base.BaseRcAdapterHelper;
import com.ekuaitu.kuaitu.base.BaseRcQuickAdapter;
import com.ekuaitu.kuaitu.bean.MyMessageBean;
import com.ekuaitu.kuaitu.bean.SearchPositionBean;
import com.ekuaitu.kuaitu.utils.TimeUtils;

/**
 * Created by Michael Pi on 2016/12/12.
 */

public class SearchPositionAdapter extends BaseRcQuickAdapter<Tip, BaseRcAdapterHelper> {
    private int type;

    public SearchPositionAdapter(Context context, int layoutResId, int type) {
        super(context, layoutResId);
        this.type = type;
    }

    @Override
    protected void convert(BaseRcAdapterHelper helper, Tip item) {
        helper.setText(R.id.position_item_search, item.getName());
        if (type == 1) {
            helper.setImageResource(R.id.imageView_search, R.drawable.icon_navi);
        } else {
            helper.setImageResource(R.id.imageView_search, R.drawable.icon_history);
        }
    }
}


